package cn.ddm.hrm.exception;

/**
 * 错误码枚举
 */
public enum ErrorCode {
    //不可为空的错误码
    CODE_400_PARAM_VALID(400001,"参数校验错误！"),
    CODE_500_SYSTEM_ERROR(500001,"内部错误，请联系管理员！"),
    CODE_403_SYSTEM_ERROR(500403,"没有权限，请联系管理员！"),
    CODE_400002_PWD_EQUAL(400002,"两次密码不一致！"),
    CODE_400_COURSE_GRADE_ILLEGAL(400005,"参数非法"),
    CODE_400_COURSE_LINE_ILLEGAL(400006,"请选中数据再操作"),
    CODE_400_COURSE_TYPE_ILLEGAL(400007,"请选中箱管课程类型"),
    CODE_400_USER_IMG_CODE(400008,"系统错误,请稍后重试"),
    CODE_400_USER_PHONE(400009,"请输入手机号"),
    CODE_400_USER_CODE(400010,"请输入验证码"),
    CODE_400_AUTH_EQUAL(400014,"请输入正确用户名或密码！"),
    CODE_400_CODE_EQUAL(400011,"两次验证码不一致,请重新输入图形验证码"),
    CODE_400_USER_PHONE_ISNULL(400012,"你已经注册过,请直接登录"),
    CODE_400_USER_CODE_TIME(400013,"验证码已经过期,请重新刷新验证码,重新填写"),
    CODE_400003_EMP_EQUAL(400003,"您已经入驻过店铺了！登录后可以添加新的店铺！！"),
    CODE_400003_TENANT_EQUAL(400002,"租户已经入驻！直接登录！");

    private int code;
    private String message;

    ErrorCode(int code, String message) {
        this.code = code;
        this.message = message;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    @Override
    public String toString() {
        return "ErrorCode{" +
                "code=" + code +
                ", message='" + message + '\'' +
                '}';
    }
}
